mustBePresentAndValid

fun KeyBindingVerifier.Companion.mustBePresentAndValid(holderPubKeyExtractor: (JsonObject) -> AsymmetricJWK? = HolderPubKeyInConfirmationClaim, challenge: JsonObject? = null): KeyBindingVerifier.MustBePresentAndValid<SignedJWT>(source)

Factory method for creating a KeyBindingVerifier which applies the rules described in keyBindingJWTProcess.

Parameters

holderPubKeyExtractor

a function that extracts the holder's public key from the payload of the SD-JWT. If not provided, it is assumed that the SD-JWT issuer used the confirmation claim (see cnf) for this purpose.

challenge

an optional challenge provided by the verifier, to be signed by the holder as the Key binding JWT. If provided, Key Binding JWT payload should contain the challenge as is.

See also

keyBindingJWTProcess